﻿using Newtonsoft.Json;
using System.Collections.Generic;

namespace Onetube.Entities.ActivityQuery
{

   public class PageInfo
    {

        [JsonProperty("totalResults")]
        public int TotalResults { get; set; }

        [JsonProperty("resultsPerPage")]
        public int ResultsPerPage { get; set; }
    }

    public class Default
    {

        [JsonProperty("url")]
        public string Url { get; set; }
    }

    public class Medium
    {

        [JsonProperty("url")]
        public string Url { get; set; }
    }

    public class High
    {

        [JsonProperty("url")]
        public string Url { get; set; }
    }

    public class Thumbnails
    {

        [JsonProperty("default")]
        public Default Default { get; set; }

        [JsonProperty("medium")]
        public Medium Medium { get; set; }

        [JsonProperty("high")]
        public High High { get; set; }
    }

    public class Snippet
    {

        [JsonProperty("publishedAt")]
        public string PublishedAt { get; set; }

        [JsonProperty("channelId")]
        public string ChannelId { get; set; }

        [JsonProperty("title")]
        public string Title { get; set; }

        [JsonProperty("description")]
        public string Description { get; set; }

        [JsonProperty("thumbnails")]
        public Thumbnails Thumbnails { get; set; }

        [JsonProperty("channelTitle")]
        public string ChannelTitle { get; set; }

        [JsonProperty("type")]
        public string Type { get; set; }
    }

    public class Upload
    {

        [JsonProperty("videoId")]
        public string VideoId { get; set; }
    }

    public class ResourceId
    {

        [JsonProperty("kind")]
        public string Kind { get; set; }

        [JsonProperty("videoId")]
        public string VideoId { get; set; }
    }

    public class PlaylistItem
    {

        [JsonProperty("resourceId")]
        public ResourceId ResourceId { get; set; }

        [JsonProperty("playlistId")]
        public string PlaylistId { get; set; }

        [JsonProperty("playlistItemId")]
        public string PlaylistItemId { get; set; }
    }

    public class ResourceId2
    {

        [JsonProperty("kind")]
        public string Kind { get; set; }

        [JsonProperty("videoId")]
        public string VideoId { get; set; }
    }

    public class SeedResourceId
    {

        [JsonProperty("kind")]
        public string Kind { get; set; }

        [JsonProperty("videoId")]
        public string VideoId { get; set; }
    }

    public class Recommendation
    {

        [JsonProperty("resourceId")]
        public ResourceId2 ResourceId { get; set; }

        [JsonProperty("reason")]
        public string Reason { get; set; }

        [JsonProperty("seedResourceId")]
        public SeedResourceId SeedResourceId { get; set; }
    }

    public class ContentDetails
    {

        [JsonProperty("upload")]
        public Upload Upload { get; set; }

        [JsonProperty("playlistItem")]
        public PlaylistItem PlaylistItem { get; set; }

        [JsonProperty("recommendation")]
        public Recommendation Recommendation { get; set; }
    }

    public class Item
    {

        [JsonProperty("kind")]
        public string Kind { get; set; }

        [JsonProperty("etag")]
        public string Etag { get; set; }

        [JsonProperty("id")]
        public string Id { get; set; }

        [JsonProperty("snippet")]
        public Snippet Snippet { get; set; }

        [JsonProperty("contentDetails")]
        public ContentDetails ContentDetails { get; set; }
    }

    public class ActivityQueryResult
    {

        [JsonProperty("kind")]
        public string Kind { get; set; }

        [JsonProperty("etag")]
        public string Etag { get; set; }

        [JsonProperty("nextPageToken")]
        public string NextPageToken { get; set; }

        [JsonProperty("pageInfo")]
        public PageInfo PageInfo { get; set; }

        [JsonProperty("items")]
        public List<Item> Items { get; set; }
    }

}
